const express = require('express');
const compression = require('compression');
const path = require('path');

const app = express();

// 注意：compression() 中间件可以开启GZIP网络传输压缩，必须放到静态资源的前面
app.use(compression(), express.static(path.join(__dirname, './dist')));

app.listen(80, () => {
  console.log('app start at http://localhost');
});
